package cn.xfdzx.android.apps.shop.contract;

import cn.xfdzx.android.apps.shop.base.BaseView;
import cn.xfdzx.android.apps.shop.bean.AddressListBeen;
import cn.xfdzx.android.apps.shop.bean.ApplyShopInBeen;
import cn.xfdzx.android.apps.shop.bean.BankCardBeen;
import cn.xfdzx.android.apps.shop.bean.DeleteAddressBeen;
import cn.xfdzx.android.apps.shop.bean.LogisticsBeen;
import cn.xfdzx.android.apps.shop.bean.NewOrderBeen;
import io.reactivex.Flowable;


/**
 * @author azheng
 * @date 2018/6/4.
 * Description：
 */

public interface ConfirmRetailContract {
    interface Model {
        Flowable<AddressListBeen> initAddressData(String page, String limit);
        Flowable<LogisticsBeen> logistics(String address_id, String orderKey);

//        Flowable<NewOrderBeen> confirmOrder(String orderKey, String couponId, String marks, String payType, String pinkId, String seckill_id, String addressId, String useIntegral, String leftName, String rightName);
        Flowable<NewOrderBeen> confirmRetail(String orderKey, String couponId, String marks, String payType, String addressId, String leftName, String rightName, String pick_up_time, String reserved_mobile_phone, String delivery_method, String logistics_type, String order_express_type);
        Flowable<DeleteAddressBeen> delectAddress(String id);
        Flowable<DeleteAddressBeen> defultAddress(String id);
    }

    interface View extends BaseView {
        @Override
        void showLoading();

        @Override
        void hideLoading();

        @Override
        void onError(Throwable throwable);

        void onInitAddressSuccess(AddressListBeen bean);
        void onLogisticsSuccess(LogisticsBeen bean);

        void onConfirmOrderSuccess(NewOrderBeen bean);
        void onDelectSuccess(DeleteAddressBeen bean,int position);
        void onDefaultSuccess(DeleteAddressBeen bean,int position);

    }

    interface Presenter {
        void delectAddress (String id,int position);
        void initAddressData(String page, String limit);
        void logistics(String address_id, String orderKey);
        void defaultAddress(String id, int position);


        /**
         *
         */
//        void confirmOrder(String orderKey, String couponId, String marks, String payType, String pinkId, String seckill_id, String addressId, String useIntegral, String leftName, String rightName);

        void confirmRetail(String orderKey, String couponId, String marks, String payType, String addressId, String leftName, String rightName, String pick_up_time, String reserved_mobile_phone, String delivery_method, String logistics_type, String order_express_type);

    }
}
